package engine.model;

import engine.Force;
import engine.Position;
import engine.Velocity;
import engine.model.Environment;

public abstract class PhysicsObject {
	private int mass;
	private int charge;
	private Force netForce;
	private Position pos;
	private Velocity velocity;
	
	public PhysicsObject(int mass, int charge, Position position) {
		this.setMass(mass);
		this.setCharge(charge);
		this.setPosition(position);
		this.setVelocity(new Velocity(0,0));
	}
	
	public PhysicsObject(int mass, int charge, Position position, Velocity velocity) {
		this(mass, charge, position);
		this.setVelocity(velocity);
	}

	public int getCharge() {
		return charge;
	}

	public void setCharge(int charge) {
		this.charge = charge;
	}
	
	public Velocity getVelocity() {
		return velocity;
	}

	public void setVelocity(Velocity velocity) {
		this.velocity = velocity;
	}

	public int getMass() {
		return mass;
	}

	public void setMass(int mass) {
		this.mass = mass;
	}

	public Force getNetForce() {
		return netForce;
	}

	public void setNetForce(Force netForce) {
		this.netForce = netForce;
	}
	
	public Position getPosition(){
		return pos;
	}
	
	public void setPosition (Position position){
		pos = position;
	}
	
	abstract public void tick(Environment env);
}
